package ar.com.tallerdos.smartdinner.activity;

import java.util.ArrayList;

import ar.com.tallerdos.smartdinner.business.AgregadoBusiness;
import ar.com.tallerdos.smartdinner.model.Agregado;

public class SeleccionarSalsasActivity extends SeleccionMultipleActivity<Agregado> {

    @Override
    protected Agregado getItemById(Integer id) {
	return AgregadoBusiness.findById(id);
    }

    @Override
    protected void cargarItems() {
	this.items = new ArrayList<Agregado>();
	for (Agregado a : AgregadoBusiness.findAll()) {
	    if (a.esSalsa()) {
		this.items.add(a);
	    }
	}
    }

}
